.hand {
  cursor: pointer;
}

.FlexBox {
  display: flex;
  @extend .s-col-center;
}

.s-flex-wrap {
  flex-wrap: wrap;
}

.s-flex-nowrap {
  flex-wrap: nowrap;
}

.s-col-center {
  align-items: center;
}

.s-col-top {
  align-items: flex-start;
}

.s-col-bottom {
  align-items: flex-end;
}

.s-row-center {
  justify-content: center;
}

.s-row-left {
  justify-content: flex-start;
}

.s-row-right {
  justify-content: flex-end;
}

.s-row-between {
  justify-content: space-between;
}

.s-row-around {
  @extend .flex;
  justify-content: space-around;
}
.flex-column {
  display: flex;
  flex-direction: column;
}
/* flex */
.flex {
  display: flex;
}

.flx-center {
  @extend .flex;
  align-items: center;
  justify-content: center;
}

.flx-justify-between {
  @extend .flex;
  align-items: center;
  justify-content: space-between;
}

.flx-between {
  @extend .flex;
  justify-content: space-between;
}

.flx-align-center {
  @extend .flex;
  align-items: center;
}

/* position */
.posR {
  position: relative;
}

/* clearfix */
.clearfix::after {
  display: block;
  height: 0;
  overflow: hidden;
  clear: both;
  content: "";
}

/* 文字单行省略号 */
.sle {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 文字多行省略号 */
.mle {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

/* 文字多了自动換行 */
.break-word {
  word-break: break-all;
  word-wrap: break-word;
}

/* fade-transform */
.fade-transform-leave-active,
.fade-transform-enter-active {
  transition: all 0.2s;
}

.fade-transform-enter-from {
  opacity: 0;
  transition: all 0.2s;
  transform: translateX(-30px);
}

.fade-transform-leave-to {
  opacity: 0;
  transition: all 0.2s;
  transform: translateX(30px);
}

/* breadcrumb-transform */
.breadcrumb-enter-active {
  transition: all 0.2s;
}

.breadcrumb-enter-from,
.breadcrumb-leave-active {
  opacity: 0;
  transform: translateX(10px);
}

/* nprogress */
#nprogress .bar {
  background: var(--el-color-primary) !important;
}

#nprogress .spinner-icon {
  border-top-color: var(--el-color-primary) !important;
  border-left-color: var(--el-color-primary) !important;
}

#nprogress .peg {
  box-shadow: 0 0 10px var(--el-color-primary), 0 0 5px var(--el-color-primary) !important;
}

/* 外边距、内边距全局样式 */
@for $i from 0 through 100 {
  .mt#{$i} {
    margin-top: #{$i}px !important;
  }
  .rounded-#{$i} {
    border-radius: #{$i}px !important;
  }
  .gap-#{$i} {
    gap: #{$i}px !important;
  }
  .mr#{$i} {
    margin-right: #{$i}px !important;
  }
  .left-#{$i} {
    left: #{$i}px !important;
  }
  .left-#{$i} {
    left: #{$i}px !important;
  }
  .right {
    right: #{$i}px !important;
  }
  .mb#{$i} {
    margin-bottom: #{$i}px !important;
  }

  .ml#{$i} {
    margin-left: #{$i}px !important;
  }

  .pt#{$i} {
    padding-top: #{$i}px !important;
  }

  .pr#{$i} {
    padding-right: #{$i}px !important;
  }

  .pb#{$i} {
    padding-bottom: #{$i}px !important;
  }

  .pl#{$i} {
    padding-left: #{$i}px !important;
  }
}

// 添加特殊圆角类
.rounded-50 {
  border-radius: 50% !important;
}
$pagePadding: 12px;
.wh100 {
  width: 100%;
  height: 100%;
}

.YouSheBiaoTiHei {
  font-family: YouSheBiaoTiHei;
}

.filterText {
  writing-mode: horizontal-tb;
  user-select: text;
  text-orientation: upright;
  word-spacing: 0px;
  letter-spacing: 0px;
}
.m-auto {
  margin: auto;
}
.t-center {
  text-align: center;
}
.flex1 {
  flex: 1;
}
.posZero {
  left: 0;
  top: 0;
}
.pos50 {
  left: 50%;
  top: 50%;
}
.posZeroB {
  bottom: 0;
  left: 0;
}
.posCenter {
  @extend .pos50;
  transform: translate(-50%, -50%);
}
.posLCenter {
  left: 50%;
  transform: translateX(-50%);
}
.posTCenter {
  top: 50%;
  transform: translateY(-50%);
}
.page-container {
  padding: 0 $pagePadding;
  @extend .wh100;
}
.relative {
  position: relative;
}
.absolute {
  position: absolute;
}

.l-t-center {
  @extend .FlexBox;
  @extend .s-row-center;
}
.scroll-y {
  overflow-y: auto;
  &::-webkit-scrollbar {
    width: 5px;
    height: 5px;
  }
  &::-webkit-scrollbar-track {
    background-color: transparent;
  }
  &::-webkit-scrollbar-thumb {
    background-color: rgba(65, 123, 214, 0.3);
    border-radius: 4px;
  }
  &::-webkit-scrollbar-thumb:hover {
    background-color: rgba(65, 123, 214, 0.6);
  }
}
.scroll-x {
  overflow-x: auto;
  &::-webkit-scrollbar {
    width: 5px;
    height: 5px;
  }
  &::-webkit-scrollbar-track {
    background-color: transparent;
  }
  &::-webkit-scrollbar-thumb {
    background-color: rgba(65, 123, 214, 0.3);
    border-radius: 4px;
  }
  &::-webkit-scrollbar-thumb:hover {
    background-color: rgba(65, 123, 214, 0.6);
  }
}

@mixin button-style($color) {
  padding: 0 16px;
  background: $color;
  color: white;
  border: none;
  font-size: 14px;
  border-radius: 4px;
  line-height: 34px;
  height: 34px;
  cursor: pointer;
  transition: background-color 0.3s ease, filter 0.3s ease;

  &:hover {
    filter: brightness(0.9);
  }
}

.addBtn {
  @extend .FlexBox;
  @extend .gap-6;
  @include button-style(linear-gradient(135deg, #667eea 0%, #764ba2 100%));
}
.addBtn-small {
  @extend .addBtn;
  padding: 0 12px;
  font-size: 12px;
  height: 30px;
}
